<?php
/**
 * Model DNS zaznamu
 * @author Tomas Srna
 * @package bakalarka
 */

class HostingFtpModel extends Model
{
	protected function __construct()
	{
		$this->_table = 'ftp';
		$this->_fields = array(
			// $name, $datatype, $pk = false,
			// $allownull = false, $default = NULL, $autoincrement = false
			new Field('id', 'int', true, false, NULL, true),
			new Field('updated', 'timestamp', false, true, 
					new Expression('CURRENT_TIMESTAMP')),
			new Field('hosting_id', 'int'),
			new Field('username', 'varchar(100)'),
			new Field('password_hash', 'varchar(128)', false, true),
			new Field('root', 'varchar(255)', false, true),
			new Field('count', 'int', false, true),
			new Field('accessed', 'timestamp', false, true, '0000-00-00 00:00:00'),
		);
	}
}
